1. Field of the Invention
The present invention relates to the field of input/output (I/O) management, and more particularly to an intelligent I/O manager which abstracts I/O functions between a computer system and a data acquisition card, wherein the data acquisition card may be designed for one of a plurality of different hardware platforms, and wherein the computer program operates in a plurality of privilege modes.
2. Description of the Related Art
Computer system expansion devices, or input/output (I/O) devices, may be coupled to computer systems in a variety of manners. Typically, a computer program executing on a computer system communicates with the input/output device via storage components, such as registers or memory, to control and/or receive information from the input/output device. A read/write from/to a storage component on an input/output device is henceforth referred to as an input/output operation. The manner in which the input/output device is coupled to the computer system in part determines the manner in which the computer program communicates with the input/output device, that is, the manner in which the input/output operations are performed.
One manner of coupling input/output devices to a computer system allows a computer program executing on the computer system to perform input/output operations by executing direct input/output instructions which read/write registers located on the input/output device. An example of such a coupling manner is through an expansion bus. Examples of currently available expansion buses are the AT or ISA (Industry Standard Architecture) bus, the EISA (Extended Industry Standard Architecture) bus, and the PCI (Peripheral Component Interconnect) bus. In addition, the input/output device may be configured as a PCMCIA (Personal Computer Memory Card International Association) card, also referred to as a PC card. The registers of input/output devices which have these interfaces are accessible by the computer program executing direct input/output instructions.
A second manner of coupling input/output devices to a computer system requires a computer program to communicate with the input/output device by a more indirect means. In other words, the registers on the input/output device are not directly accessible by a direct input/output instruction of the computer system. Examples of the indirect coupling manner include different types of I/O interfaces or platforms, including the VXI bus (VME Extensions for Instrumentation) bus, and the GPIB (General Purpose Interface Bus), among others. These interfaces are popular in the instrumentation or test measurement industry. In addition, the input/output device may be adapted for indirectly coupling to a computer system via a serial port or parallel port.
In many cases it is desired for a computer program executing on a computer system to be able to communicate with expansion or input/output devices in a portable manner, i.e., regardless of how the expansion device is coupled to the computer system. In other words, software developers for such devices desire to develop portable code which is highly reusable and maintainable by virtue of its hardware platform independence.
One area where a portable computer program is desired is in the field of data acquisition. For example, a data acquisition card which is software controlled may be coupled to the computer system by any of the various interfaces described above. The computer program causes the computer system to generate a plurality of bits which are provided to the data acquisition card which configure and/or control the data acquisition card or cause the data acquisition card to provide data in response. These plurality of bits differ depending upon the type of platform for which the data acquisition card is configured, including the manner in which the card is coupled to the system. In other words, different bits are required to be transferred to the data acquisition card, depending upon whether the card is configured to reside on an expansion bus, such as the PCI bus, is coupled to a serial or a parallel port, is a PCMCIA card, or is a VXI or GPIB card.
Computer programs which communicate with input/output devices execute under the supervision of operating systems running on the computer system. Examples of such operating systems include "UNIX", "MS-DOS", "WINDOWS", "WINDOWS NT", the "MACINTOSH" operating system, etc. For security purposes, operating systems typically employ one or more different privilege modes in which computer programs execute. The operating systems are configured such that certain operations, such as the execution of input/output instructions, the execution of instructions which access particular memory ranges, etc., may only be executed in certain privilege modes. The same code reusability and maintainability issues which exist in regard to the input/output device coupling manners, as described above, also exist in regards to privilege modes.
Therefore, an improved system and method is desired for enabling a single computer program to communicate with an expansion device or expansion card regardless of the I/O platform in which the expansion device is configured and regardless of the privilege mode in which the computer program is executing with respect to the operating system running on the computer system.